package com.heima.behavior.controller.v1;

import com.heima.behavior.service.ApUnLikesBehaviorService;
import com.heima.model.behavior.dtos.UnLikesBehaviorDTO;
import com.heima.model.common.dtos.ResponseResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @Author XHui
 * @Since 2024/3/3 14:34
 * @Version 1.0
 */
@Api(value = "不喜欢行为管理", tags = "不喜欢行为管理")
@RestController
@RequestMapping("api/v1/un_likes_behavior")
public class ApUnLikesBehaviorController {

    @Resource
    private ApUnLikesBehaviorService apUnLikesBehaviorService;

    @ApiOperation(value = "不喜欢行为接口", notes = "用于记录用户不喜欢行为")
    @PostMapping
    public ResponseResult unlikes(@RequestBody @Validated UnLikesBehaviorDTO dto) {
        return apUnLikesBehaviorService.unlikesBehavior(dto);
    }
}
